package com.ykdl.member.kid.beans;

import java.io.Serializable;

import android.text.TextUtils;

import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.ykdl.member.kid.models.FileMetas;

import net.wxxr.http.interfaces.IJsonParser;

public class PostBean implements IJsonParser, Serializable {
	
	/**
	 * {
            "display_order": 0,
            "file_ids": [
                7163
            ],
            "file_metas": [
                {
                    "download_urls": {
                        "big": "http://172.16.22.11/group1/M00/01/32/rBAWC1MZiMuAAW0fAAK0f7L1nS0619_big.png",
                        "middle": "http://172.16.22.11/group1/M00/01/32/rBAWC1MZiMuAAW0fAAK0f7L1nS0619_middle.png",
                        "origin": "http://172.16.22.11/group1/M00/01/32/rBAWC1MZiMuAAW0fAAK0f7L1nS0619.png",
                        "small": "http://172.16.22.11/group1/M00/01/32/rBAWC1MZiMuAAW0fAAK0f7L1nS0619_small.png"
                    },
                    "file_id": 7163,
                    "file_name": "haruhi.jpg",
                    "is_image": true,
                    "mime_type": "image/jpeg"
                }
            ],
            "has_image": true,
            "is_anonymous": 0,
            "is_answer": false,
            "is_like": false,
            "layer": 0,
            "likes_count": 0,
            "message": "谍战、军旅、刑侦剧，俊男美女霸气十足，来这里共同探讨，圆你一个特工梦",
            "parent_id": 635,
            "post_actor": {
                "actor_id": 6143,
                "actor_type": 1,
                "baby_profile": {
                    "baby_name": "xiaoxiao1",
                    "birthday": 1388047495,
                    "blood_type": "A",
                    "born_height": 22,
                    "born_weight": 960,
                    "gender": 1,
                    "modified_time": 1394158091.254753,
                    "user_id": 6143
                },
                "created_time": 1394156333,
                "display_name": "xiaoxiao1",
                "email": "shanpf@7500.com.cn",
                "gender": 0,
                "level": 5,
                "phone": null,
                "profile": {
                    "birthday": 1388047495,
                    "gender": 0,
                    "modified_time": 1394158131.527766,
                    "region": "%E5%8C%97%E4%BA%AC",
                    "signature": "%E5%8C%97%E4%BA%AC",
                    "user_id": 6143
                },
                "total_gold": 20,
                "total_xp": 50,
                "user_id": 6143
            },
            "post_actor_display_name": "xiaoxiao1",
            "post_actor_id": 6143,
            "post_id": 635,
            "post_time": 1394433269.341122,
            "source": "groups",
            "source_id": 40,
            "topic_id": 635
        }
	 */
	private int display_order;
	private int[] file_ids;
	private FileMetas[] file_metas;
	private boolean has_image;
	private int is_anonymous;
	private boolean is_answer;
	private boolean is_like;
	private int layer;
	private int likes_count;
	private String message;
	private int parent_id;
	private UserBean post_actor;
	private String post_actor_display_name;
	private int post_actor_id;
	private int post_id;
	private float post_time;
	private String source;
	private int source_id;
	private int topic_id;
	private Listinfobean group ;
	public Listinfobean getGroup() {
		return group;
	}
	public int getDisplay_order() {
		return display_order;
	}
	public void setDisplay_order(int display_order) {
		this.display_order = display_order;
	}
	public int[] getFile_ids() {
		return file_ids;
	}
	public void setFile_ids(int[] file_ids) {
		this.file_ids = file_ids;
	}
	public FileMetas[] getFile_metas() {
		return file_metas;
	}
	public void setFile_metas(FileMetas[] file_metas) {
		this.file_metas = file_metas;
	}
	public boolean isHas_image() {
		return has_image;
	}
	public void setHas_image(boolean has_image) {
		this.has_image = has_image;
	}
	public int getIs_anonymous() {
		return is_anonymous;
	}
	public void setIs_anonymous(int is_anonymous) {
		this.is_anonymous = is_anonymous;
	}
	public boolean isIs_answer() {
		return is_answer;
	}
	public void setIs_answer(boolean is_answer) {
		this.is_answer = is_answer;
	}
	public boolean isIs_like() {
		return is_like;
	}
	public void setIs_like(boolean is_like) {
		this.is_like = is_like;
	}
	public int getLayer() {
		return layer;
	}
	public void setLayer(int layer) {
		this.layer = layer;
	}
	public int getLikes_count() {
		return likes_count;
	}
	public void setLikes_count(int likes_count) {
		this.likes_count = likes_count;
	}
	public String getMessage() {
		return message;
	}
	public void setMessage(String message) {
		this.message = message;
	}
	public int getParent_id() {
		return parent_id;
	}
	public void setParent_id(int parent_id) {
		this.parent_id = parent_id;
	}
	public UserBean getPost_actor() {
		return post_actor;
	}
	public void setPost_actor(UserBean post_actor) {
		this.post_actor = post_actor;
	}
	public String getPost_actor_display_name() {
		return post_actor_display_name;
	}
	public void setPost_actor_display_name(String post_actor_display_name) {
		this.post_actor_display_name = post_actor_display_name;
	}
	public int getPost_actor_id() {
		return post_actor_id;
	}
	public void setPost_actor_id(int post_actor_id) {
		this.post_actor_id = post_actor_id;
	}
	public int getPost_id() {
		return post_id;
	}
	public void setPost_id(int post_id) {
		this.post_id = post_id;
	}
	public float getPost_time() {
		return post_time;
	}
	public void setPost_time(float post_time) {
		this.post_time = post_time;
	}
	public String getSource() {
		return source;
	}
	public void setSource(String source) {
		this.source = source;
	}
	public int getSource_id() {
		return source_id;
	}
	public void setSource_id(int source_id) {
		this.source_id = source_id;
	}
	public int getTopic_id() {
		return topic_id;
	}
	public void setTopic_id(int topic_id) {
		this.topic_id = topic_id;
	}
	@Override
	public IJsonParser parse(String json) throws Exception {
		if (TextUtils.isEmpty(json)) {
			GsonBuilder builder = new GsonBuilder();
			Gson gson = builder.create();
			return gson.fromJson(json, PostBean.class);
		}
		return null;
	}
	
}
